package nc.bs.fa.backgroundtask;

import nc.bs.framework.common.NCLocator;
import nc.bs.pub.pa.PreAlertObject;
import nc.bs.pub.pa.PreAlertReturnType;
import nc.bs.pub.taskcenter.BgWorkingContext;
import nc.bs.pub.taskcenter.IBackgroundWorkPlugin;
import nc.itf.fa.copycard.ICopyCard;
import nc.pub.batm.util.ExceptionUtils;
import nc.vo.pub.BusinessException;
import nc.vo.pub.lang.MultiLangText;

public class CopyCardSychroAutoEt implements IBackgroundWorkPlugin {
	@Override
	public PreAlertObject executeTask(BgWorkingContext bgwc)
			throws BusinessException { 
		MultiLangText text = new MultiLangText();
		PreAlertObject pao = new PreAlertObject();
		pao.setReturnType(PreAlertReturnType.RETURNNOTHING);
		pao.setReturnObj(text);
		try { 
			NCLocator.getInstance().lookup(ICopyCard.class).doCopy();
		} catch (Exception e) {
			e.printStackTrace();
			throw new BusinessException(ExceptionUtils.getStackTrace(e));
			
		}
		return pao;
	}
}
